package com.example.animation;

import android.content.Context;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.Canvas;
import android.graphics.Matrix;
import android.graphics.Paint;
import android.util.AttributeSet;
import android.view.View;

import androidx.annotation.Nullable;

public class animation extends View {
    public animation(Context context) {
        super(context);
    }

    public animation(Context context, @Nullable AttributeSet attrs) {
        super(context, attrs);
    }

    @Override
    protected void onDraw(Canvas canvas) {
        super.onDraw(canvas);
        Bitmap dogBitmap = BitmapFactory.decodeResource(getResources(), R.drawable.dog);
        Paint paint = new Paint();
        Matrix matrix = new Matrix();
        canvas.drawBitmap(dogBitmap, matrix, paint);
    }
}
